Total Lines | 36 |
Lines | 0 |
Ratio | 0 % |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | import test from 'ava' |
||
27 | test('All aliases', t => { |
||
28 | let testing = null |
||
29 | |||
30 | class TestSyncer extends makeBaseDriver() { |
||
31 | refresh() { |
||
32 | t.is(testing, 'refresh') |
||
33 | } |
||
34 | } |
||
35 | |||
36 | addVueWithPlugin(t, { |
||
37 | aliases: true, |
||
38 | driver: TestSyncer, |
||
39 | feathers: { |
||
40 | service(service) { |
||
41 | t.is(testing, 'service') |
||
42 | t.is(service, 'manual-test') |
||
43 | } |
||
44 | } |
||
45 | }) |
||
46 | const {Vue} = t.context |
||
47 | |||
48 | const instance = new Vue({ |
||
49 | sync: { |
||
50 | test: 'test' |
||
51 | } |
||
52 | }) |
||
53 | |||
54 | testing = 'loading' |
||
55 | t.is(instance.$loading, true) |
||
56 | |||
57 | testing = 'refresh' |
||
58 | instance.$refresh() |
||
59 | |||
60 | testing = 'service' |
||
61 | instance.$service('manual-test') |
||
62 | }) |
||
63 | |||
87 |